package edu.uit.se.slgroup.construct.services;

import java.util.List;

import org.springframework.beans.factory.annotation.Autowired;

import edu.uit.se.slgroup.construct.dao.SubCategoryDao;
import edu.uit.se.slgroup.construct.domain.SubCategory;
import edu.uit.se.slgroup.construct.domain.SubCategoryTemp;

public class SubCategoryServiceImpl implements SubCategoryService{

	@Autowired
	SubCategoryDao subCategoryDao;
	
	public int insertSubCategory(SubCategory subCategory) {
		return subCategoryDao.insertSubCategory(subCategory);
	}

	public List<SubCategory> getSubCategoryList() {
		return subCategoryDao.getSubCategoryList();
	}

	public SubCategory getSubCategoryById(int id) {
		return subCategoryDao.getSubCategoryById(id);
	}

	public int updateSubCategory(SubCategory subCategory) {
		return subCategoryDao.updateSubCategory(subCategory);
	}

	public int deleteSubCategory(int id) {
		return subCategoryDao.deleteSubCategory(id);
	}

	public List<SubCategoryTemp> getSubCategoryTempList() {
		return subCategoryDao.getSubCategoryTempList();
	}

}
